package com.ying.tests.BBBbook.java8.Chapter3.自定义函数时接口;


import java.util.*;

public class Test {

    public static void main(String[] args) {
        String s1 = "小明", s2 = "小颖";
        List<String> student = getStudent(s1, s2, (t1, t2) -> {
            List<String> list = new ArrayList<>();
            list.add(t1);
            list.add(t2);
            return list;
        });
        System.out.println(student);
    }


    public static List<String> getStudent(String s1, String s2, TestInterface<String, String> testInterface) {
        return testInterface.process(s1, s2);
    }

}
